Security News
New Python Packaging Proposal Aims to Solve Phantom Dependency Problem with SBOMs
PEP 770 proposes adding SBOM support to Python packages to improve transparency and catch hidden non-Python dependencies that security tools often miss.
@cloudflare/component-icon
Advanced tools
Cloudflare Icon Component
Installation with yarn is recommended
$ yarn add @cloudflare/component-icon
import React from 'react';
import { Icon } from '../../src';
import iconTypes from '../../src/iconTypes';
import { createComponent } from '@cloudflare/style-container';
const ColorWrapper = createComponent(
() => ({
backgroundColor: '#f1f1f1',
paddingTop: '10px',
paddingBottom: '10px',
paddingLeft: '15px',
maxWidth: 750,
display: 'block'
}),
'span'
);
const TextWrapper = createComponent(
() => ({
paddingRight: '20px',
paddingLeft: '5px'
}),
'span'
);
const IconComponent = () => (
<div>
<p>Types:</p>
<Icons>
{iconTypes.map(iconType => (
<IconWrapper key={iconType}>
<Icon label={iconType} type={iconType} size="3x" />
<pre>{iconType}</pre>
</IconWrapper>
))}
</Icons>
<p>Sizes:</p>
<p>
<Icon label="2x" size="2x" type="gear" />
<TextWrapper>2x</TextWrapper>
<Icon label="2.5x" size="2.5x" type="gear" />
<TextWrapper>2.5x</TextWrapper>
<Icon label="3x" size="3x" type="gear" />
<TextWrapper>3x</TextWrapper>
<Icon label="3.5x" size="3.5x" type="gear" />
<TextWrapper>3.5x</TextWrapper>
<Icon label="4x" size="4x" type="gear" />
<TextWrapper>4x</TextWrapper>
</p>
<p>Colors:</p>
<p>
<ColorWrapper>
<Icon label="default" size="2x" type="search" color="default" />
<TextWrapper>Default</TextWrapper>
<Icon label="primary" size="2x" type="caret-right" color="primary" />
<TextWrapper>Primary</TextWrapper>
<Icon label="success" size="2x" type="ok" color="success" />
<TextWrapper>Success</TextWrapper>
<Icon label="warning" size="2x" type="info-sign" color="warning" />
<TextWrapper>Warning</TextWrapper>
<Icon label="danger" size="2x" type="exclamation-sign" color="danger" />
<TextWrapper>Danger</TextWrapper>
<Icon label="black" size="2x" type="remove" color="black" />
<TextWrapper>Black</TextWrapper>
<Icon label="white" size="2x" type="shield" color="white" />
<TextWrapper>White</TextWrapper>
</ColorWrapper>
</p>
</div>
);
const gutterSize = '0.5em';
const Icons = createComponent(() => ({
display: 'grid',
gridTemplateColumns: 'repeat(auto-fill, minmax(8rem, 1fr))',
gridAutoRows: '1fr',
margin: `0 -${gutterSize}`,
'&::before': {
content: `''`,
width: '0',
paddingBottom: '100%',
gridRow: '1 / 1',
gridColumn: '1 / 1'
}
}));
const IconWrapper = createComponent(({ theme }) => ({
display: 'flex',
alignItems: 'center',
flexDirection: 'column',
justifyContent: 'center',
margin: gutterSize,
background: theme.colors.gray[9],
'& svg': {
flex: 1,
marginTop: '1.5em'
},
'&:first-child': {
gridRow: '1 / 1',
gridColumn: '1 / 1'
}
}));
export default IconComponent;
FAQs
Cloudflare Icon Component
The npm package @cloudflare/component-icon receives a total of 11,827 weekly downloads. As such, @cloudflare/component-icon popularity was classified as popular.
We found that @cloudflare/component-icon demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 0 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
PEP 770 proposes adding SBOM support to Python packages to improve transparency and catch hidden non-Python dependencies that security tools often miss.
Security News
Socket CEO Feross Aboukhadijeh discusses open source security challenges, including zero-day attacks and supply chain risks, on the Cyber Security Council podcast.
Security News
Research
Socket researchers uncover how threat actors weaponize Out-of-Band Application Security Testing (OAST) techniques across the npm, PyPI, and RubyGems ecosystems to exfiltrate sensitive data.